package org.dromara.speed.proto;

//import com.alibaba.fastjson2.JSONObject;
//import net.devh.boot.grpc.client.inject.GrpcClient;
//import org.dromara.speed.domain.AOrderBo;
//import org.springframework.stereotype.Service;
//
//@Service
//public class ExternalServiceClient {
//
//    @GrpcClient("manual-server") // 对应配置中的客户端名
//    private ExternalServiceGrpc.ExternalServiceBlockingStub blockingStub;
//
//    public PushOrderResponse callService(AOrderBo bo, String secretKey) {
//
//        PushOrderRequest.Builder request = PushOrderRequest.newBuilder();
//        request.setParams(JSONObject.toJSONString(bo));
//        request.setSecretKey(secretKey); // 设置密钥
//
//        return blockingStub.pushOrder(request.build());
//    }
//}
